<?php namespace Zm345\Com\SDK\OpenLib\Copen\Enterpr\Article;use Zm345\Com\SDK\OpenLib\Copen\ACopen;class ArticleViewAdd extends ACopen{protected$params=array();public function setId($id=null){$this->params['id']=$id;return$this;}public function exec(&$errorMsg=""){$errorMsg="";if(!isset($this->params['id'])||!is_int($this->params['id'])&&!ctype_digit($this->params['id'])){$errorMsg="“id”参数错误";}if($errorMsg)return false;$articleUpdate=$this->openLib->copenQuery('Enterpr\Article\ArticlesUpdate');if(false===$articleUpdate->setRefIds($this->params['id'])->setRefStatuses("released")->setViews()->execute()){$errorMsg=$articleUpdate->errorInfo();return false;}return true;}}?>